{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 143,
   "metadata": {},
   "outputs": [],
   "source": [
    "from macd_monitor import monitor\n",
    "import datetime\n",
    "from jqdatasdk import *\n",
    "from talib import abstract as tfun"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 17,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "{'sign': 'gold cross', 'freq': '5m', 'avg_lift': -1.6265619833091494}"
      ]
     },
     "execution_count": 17,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "now = datetime.datetime.now()\n",
    "monitor(now, '5m')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 18,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "-1.6265619833091494"
      ]
     },
     "execution_count": 18,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": 110,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": 243,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "1480"
      ]
     },
     "execution_count": 243,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "code = '600031.XSHG'\n",
    "codesh50 = '000016.XSHG'\n",
    "count = 1480\n",
    "# freq = '5m'\n",
    "# end_dt = now\n",
    "end_dt = datetime.datetime.strptime('2021-08-17 15:01:00', '%Y-%m-%d %H:%M:%S')\n",
    "\n",
    "dfs = {}\n",
    "for freq in ['5m', '30m', '60m']:\n",
    "    df = get_bars(code,count = count, unit=freq,\n",
    "         fields=['date','open','high','low','close', 'volume', 'money'],\n",
    "              end_dt=end_dt, fq_ref_date=None,df=True)\n",
    "    dfs[freq] = df\n",
    "# df50 = get_bars(codesh50,count = count, unit=freq,\n",
    "#      fields=['date','open','high','low','close', 'volume', 'money'],\n",
    "#           end_dt=end_dt, fq_ref_date=None,df=True)\n",
    "\n",
    "\n",
    "len(df)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 112,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "-3.7693958976348085e-05\n",
      "-0.9914887058895538\n",
      "-0.7865753299471812\n",
      "-0.44633228711876693\n",
      "-0.925093075110961\n",
      "-1.0662880025074317\n",
      "-0.9404870360887552\n",
      "-1.3107622806175279\n",
      "-1.5441682895244724\n",
      "-1.5587010286286174\n",
      "-1.7902552376597103\n",
      "-1.8396142770055413\n",
      "-1.6078992736274889\n",
      "-1.616452457849038\n",
      "-1.7473240873833062\n",
      "-1.7825268784841808\n",
      "-1.852949362773193\n",
      "-1.9297821911902435\n",
      "-23.73673749536494\n"
     ]
    },
    {
     "data": {
      "text/plain": [
       "(258.1762436660359, 253.19410256410256, -1.9297821911902435)"
      ]
     },
     "execution_count": 112,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "end_dt = datetime.datetime.strptime('2021-08-17 11:01:00', '%Y-%m-%d %H:%M:%S')\n",
    "avg_lift = avg_percent(df, end_dt)\n",
    "avg_lift"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 113,
   "metadata": {},
   "outputs": [],
   "source": [
    "mdt = [\"09:30\",\"09:35\",\"09:40\",\"09:45\",\"09:50\",\"09:55\",\"10:00\",\"10:05\",\"10:10\",\"10:15\",\"10:20\",\"10:25\",\"10:30\",\"10:35\",\"10:40\",\"10:45\",\"10:50\",\"10:55\",\"11:00\",\"11:05\",\"11:10\",\"11:15\",\"11:20\",\"11:25\",\"11:30\",\"13:05\",\"13:10\",\"13:15\",\"13:20\",\"13:25\",\"13:30\",\"13:35\",\"13:40\",\"13:45\",\"13:50\",\"13:55\",\"14:00\",\"14:05\",\"14:10\",\"14:15\",\"14:20\",\"14:25\",\"14:30\",\"14:35\",\"14:40\",\"14:45\",\"14:50\",\"14:55\",\"15:00\"]"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": 249,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "2021-08-03 09:35:00 SELL {'5m': (23.550724637680986, 7.850241545893499, 54.95169082125596, True), '30m': (100.00000000000016, 100.00000000000007, 100.00000000000031, True), '60m': (99.99999999999993, 88.05108798486265, 123.89782403027448, True)} KDJ High\n",
      "2021-08-03 09:40:00 SELL {'5m': (55.94066174459919, 26.497128794093285, 114.82772764561099, True), '30m': (100.00000000000016, 100.00000000000007, 100.00000000000031, True), '60m': (99.99999999999993, 88.05108798486265, 123.89782403027448, True)} KDJ High\n",
      "2021-08-03 09:45:00 SELL {'5m': (89.27399507793253, 56.25512715340418, 155.31173092698924, True), '30m': (100.00000000000016, 100.00000000000007, 100.00000000000031, True), '60m': (99.99999999999993, 88.05108798486265, 123.89782403027448, True)} KDJ High\n",
      "2021-08-03 09:50:00 SELL {'5m': (92.12148073107915, 79.11204585120358, 118.14035049083029, True), '30m': (100.00000000000016, 100.00000000000007, 100.00000000000031, True), '60m': (99.99999999999993, 88.05108798486265, 123.89782403027448, True)} KDJ High\n",
      "2021-08-03 09:55:00 SELL {'5m': (84.34004474272915, 88.57850685058021, 75.86312052702701, False), '30m': (100.00000000000016, 100.00000000000007, 100.00000000000031, True), '60m': (99.99999999999993, 88.05108798486265, 123.89782403027448, True)} KDJ High\n",
      "2021-08-03 10:00:00 SELL {'5m': (74.7203579418343, 83.72729447188081, 56.70648488174126, False), '30m': (96.68976135488852, 98.89658711829618, 92.2761098280732, False), '60m': (99.99999999999993, 88.05108798486265, 123.89782403027448, True)} KDJ High\n",
      "2021-08-03 10:05:00 SELL {'5m': (74.49664429530182, 77.85234899328837, 67.78523489932871, False), '30m': (96.68976135488852, 98.89658711829618, 92.2761098280732, False), '60m': (99.99999999999993, 88.05108798486265, 123.89782403027448, True)} KDJ High\n",
      "2021-08-03 10:10:00 SELL {'5m': (81.208053691275, 76.80835197613698, 90.00745712155106, True), '30m': (96.68976135488852, 98.89658711829618, 92.2761098280732, False), '60m': (99.99999999999993, 88.05108798486265, 123.89782403027448, True)} KDJ High\n",
      "2021-08-03 10:15:00 SELL {'5m': (89.26174496644279, 81.6554809843398, 104.47427293064877, True), '30m': (96.68976135488852, 98.89658711829618, 92.2761098280732, False), '60m': (99.99999999999993, 88.05108798486265, 123.89782403027448, True)} KDJ High\n",
      "2021-08-03 10:20:00 SELL {'5m': (92.17002237136455, 87.54660700969406, 101.41685309470554, True), '30m': (96.68976135488852, 98.89658711829618, 92.2761098280732, False), '60m': (99.99999999999993, 88.05108798486265, 123.89782403027448, True)} KDJ High\n",
      "2021-08-03 10:25:00 SELL {'5m': (90.3617891392011, 90.59785215900276, 89.88966309959775, False), '30m': (96.68976135488852, 98.89658711829618, 92.2761098280732, False), '60m': (99.99999999999993, 88.05108798486265, 123.89782403027448, True)} KDJ High\n",
      "2021-08-03 10:30:00 SELL {'5m': (83.85984411291112, 88.79721854115887, 73.98509525641563, False), '30m': (93.81750133977134, 96.83575423155325, 87.7809955562075, False), '60m': (97.12773998488274, 98.09019904257981, 95.20282186948859, False)} KDJ High\n",
      "2021-08-03 10:35:00 SELL {'5m': (80.25477707006348, 84.82547010739184, 71.11339099540677, False), '30m': (93.81750133977134, 96.83575423155325, 87.7809955562075, False), '60m': (97.12773998488274, 98.09019904257981, 95.20282186948859, False)} KDJ High\n",
      "2021-08-03 10:40:00 SELL {'5m': (73.03609341825882, 79.05023820041107, 61.0078038539543, False), '30m': (93.81750133977134, 96.83575423155325, 87.7809955562075, False), '60m': (97.12773998488274, 98.09019904257981, 95.20282186948859, False)} KDJ High\n",
      "2021-08-03 10:45:00 SELL {'5m': (73.88535031847118, 75.72540693559777, 70.205237084218, False), '30m': (93.81750133977134, 96.83575423155325, 87.7809955562075, False), '60m': (97.12773998488274, 98.09019904257981, 95.20282186948859, False)} KDJ High\n",
      "2021-08-03 10:50:00 SELL {'5m': (71.97452229299348, 72.96532200990777, 69.99292285916493, False), '30m': (93.81750133977134, 96.83575423155325, 87.7809955562075, False), '60m': (97.12773998488274, 98.09019904257981, 95.20282186948859, False)} KDJ High\n",
      "2021-08-03 10:55:00 SELL {'5m': (74.52229299363036, 73.46072186836494, 76.6454352441612, True), '30m': (93.81750133977134, 96.83575423155325, 87.7809955562075, False), '60m': (97.12773998488274, 98.09019904257981, 95.20282186948859, False)} KDJ High\n",
      "2021-08-03 11:00:00 SELL {'5m': (68.36518046709104, 71.62066525123822, 61.85421089879668, False), '30m': (89.05559657786655, 93.1876197575087, 80.79155021858227, False), '60m': (97.12773998488274, 98.09019904257981, 95.20282186948859, False)} KDJ High\n",
      "2021-08-03 11:05:00 SELL {'5m': (66.87898089171948, 69.92215145081356, 60.792639773531306, False), '30m': (89.05559657786655, 93.1876197575087, 80.79155021858227, False), '60m': (97.12773998488274, 98.09019904257981, 95.20282186948859, False)} KDJ High\n",
      "2021-08-03 11:10:00 SELL {'5m': (66.87898089171948, 67.37438075017661, 65.8881811748052, False), '30m': (89.05559657786655, 93.1876197575087, 80.79155021858227, False), '60m': (97.12773998488274, 98.09019904257981, 95.20282186948859, False)} KDJ High\n",
      "2021-08-03 11:15:00 SELL {'5m': (70.57735771522479, 68.1117731662212, 75.50852681323198, True), '30m': (89.05559657786655, 93.1876197575087, 80.79155021858227, False), '60m': (97.12773998488274, 98.09019904257981, 95.20282186948859, False)} KDJ High\n",
      "2021-08-03 11:20:00 SELL {'5m': (73.31937334516557, 70.25857065070323, 79.44097873409027, True), '30m': (89.05559657786655, 93.1876197575087, 80.79155021858227, False), '60m': (97.12773998488274, 98.09019904257981, 95.20282186948859, False)} KDJ High\n",
      "2021-08-03 11:25:00 SELL {'5m': (69.69073022607654, 71.19582042882224, 66.68054982058513, False), '30m': (89.05559657786655, 93.1876197575087, 80.79155021858227, False), '60m': (97.12773998488274, 98.09019904257981, 95.20282186948859, False)} KDJ High\n",
      "2021-08-03 11:30:00 SELL {'5m': (65.22673543950101, 69.41227967024766, 56.85564697800774, False), '30m': (90.24943310657606, 91.0408436747379, 88.66661197025238, False), '60m': (95.01133786848061, 97.37969261778767, 90.27462836986649, False)} KDJ High\n",
      "2021-08-03 13:05:00 SELL {'5m': (60.606060606060204, 65.17450875721254, 51.46916430375555, False), '30m': (90.24943310657606, 91.0408436747379, 88.66661197025238, False), '60m': (95.01133786848061, 97.37969261778767, 90.27462836986649, False)} KDJ High\n",
      "2021-08-03 13:10:00 SELL {'5m': (66.66666666666632, 64.16648757074246, 71.66702485851403, True), '30m': (90.24943310657606, 91.0408436747379, 88.66661197025238, False), '60m': (95.01133786848061, 97.37969261778767, 90.27462836986649, False)} KDJ High\n",
      "2021-08-03 13:15:00 SELL {'5m': (67.1717171717169, 64.81481481481443, 71.88552188552185, True), '30m': (90.24943310657606, 91.0408436747379, 88.66661197025238, False), '60m': (95.01133786848061, 97.37969261778767, 90.27462836986649, False)} KDJ High\n",
      "2021-08-03 13:20:00 SELL {'5m': (64.91841491841474, 66.25226625226594, 62.250712250712354, False), '30m': (90.24943310657606, 91.0408436747379, 88.66661197025238, False), '60m': (95.01133786848061, 97.37969261778767, 90.27462836986649, False)} KDJ High\n",
      "2021-08-03 13:25:00 SELL {'5m': (62.26107226107208, 64.78373478373453, 57.21574721574717, False), '30m': (90.24943310657606, 91.0408436747379, 88.66661197025238, False), '60m': (95.01133786848061, 97.37969261778767, 90.27462836986649, False)} KDJ High\n",
      "2021-08-03 13:30:00 SELL {'5m': (61.53846153846132, 62.90598290598266, 58.80341880341864, False), '30m': (91.00529100529111, 90.10344022991114, 92.80899255605107, True), '60m': (95.01133786848061, 97.37969261778767, 90.27462836986649, False)} KDJ High\n",
      "2021-08-03 13:35:00 SELL {'5m': (63.589743589743314, 62.46309246309219, 65.84304584304557, True), '30m': (91.00529100529111, 90.10344022991114, 92.80899255605107, True), '60m': (95.01133786848061, 97.37969261778767, 90.27462836986649, False)} KDJ High\n",
      "2021-08-03 13:40:00 SELL {'5m': (59.212454212453906, 61.44688644688613, 54.74358974358945, False), '30m': (91.00529100529111, 90.10344022991114, 92.80899255605107, True), '60m': (95.01133786848061, 97.37969261778767, 90.27462836986649, False)} KDJ High\n",
      "2021-08-03 13:45:00 SELL {'5m': (59.88095238095212, 60.89438339438306, 57.85409035409022, False), '30m': (91.00529100529111, 90.10344022991114, 92.80899255605107, True), '60m': (95.01133786848061, 97.37969261778767, 90.27462836986649, False)} KDJ High\n",
      "2021-08-03 13:50:00 SELL {'5m': (67.26190476190447, 62.11843711843679, 77.54884004883985, True), '30m': (91.00529100529111, 90.10344022991114, 92.80899255605107, True), '60m': (95.01133786848061, 97.37969261778767, 90.27462836986649, False)} KDJ High\n",
      "2021-08-03 13:55:00 SELL {'5m': (74.40476190476166, 67.18253968253937, 88.84920634920624, True), '30m': (91.00529100529111, 90.10344022991114, 92.80899255605107, True), '60m': (95.01133786848061, 97.37969261778767, 90.27462836986649, False)} KDJ High\n",
      "2021-08-03 14:00:00 SELL {'5m': (88.0952380952378, 76.58730158730127, 111.11111111111089, True), '30m': (95.23809523809537, 92.16427311665409, 101.38573948097795, True), '60m': (94.48223733938009, 95.54043839758106, 92.36583522297815, False)} KDJ High\n",
      "2021-08-03 14:05:00 SELL {'5m': (91.96428571428554, 84.82142857142829, 106.25000000000003, True), '30m': (95.23809523809537, 92.16427311665409, 101.38573948097795, True), '60m': (94.48223733938009, 95.54043839758106, 92.36583522297815, False)} KDJ High\n",
      "2021-08-03 14:10:00 SELL {'5m': (94.79166666666661, 91.61706349206328, 101.14087301587327, True), '30m': (95.23809523809537, 92.16427311665409, 101.38573948097795, True), '60m': (94.48223733938009, 95.54043839758106, 92.36583522297815, False)} KDJ High\n",
      "2021-08-03 14:15:00 SELL {'5m': (94.79166666666661, 93.84920634920623, 96.67658730158738, True), '30m': (95.23809523809537, 92.16427311665409, 101.38573948097795, True), '60m': (94.48223733938009, 95.54043839758106, 92.36583522297815, False)} KDJ High\n",
      "2021-08-03 14:20:00 SELL {'5m': (96.87499999999989, 95.48611111111101, 99.65277777777763, True), '30m': (95.23809523809537, 92.16427311665409, 101.38573948097795, True), '60m': (94.48223733938009, 95.54043839758106, 92.36583522297815, False)} KDJ High\n",
      "2021-08-03 14:25:00 SELL {'5m': (86.97916666666646, 92.88194444444429, 75.1736111111108, False), '30m': (95.23809523809537, 92.16427311665409, 101.38573948097795, True), '60m': (94.48223733938009, 95.54043839758106, 92.36583522297815, False)} KDJ High\n",
      "2021-08-03 14:30:00 SELL {'5m': (75.13343663911826, 86.32920110192816, 52.74190771349845, False), '30m': (94.6191283977545, 93.62083821371355, 96.61570876583639, True), '60m': (94.48223733938009, 95.54043839758106, 92.36583522297815, False)} KDJ High\n"
     ]
    }
   ],
   "source": [
    "def avg_percent(df, d):\n",
    "    avg_percent = 0\n",
    "    sum_m = 0\n",
    "    sum_v = 0\n",
    "    cavg = 0\n",
    "    avg = 0\n",
    "    avg_pe_sum = 0\n",
    "    avgs = []\n",
    "    pcnt = 0\n",
    "    ncnt = 0\n",
    "    for index, row in df.iterrows():\n",
    "        sum_m += row.money\n",
    "        sum_v += row.volume\n",
    "        cavg = row.money / row.volume\n",
    "        avg = sum_m / (sum_v  + 0.00001)\n",
    "        avg_percent = ((cavg / (avg + 0.0001)) - 1) * 100\n",
    "        avg_pe_sum += avg_percent\n",
    "        avgs.append(avg_percent)\n",
    "        if avg_percent > 0:\n",
    "            pcnt += 1\n",
    "        else:\n",
    "            ncnt += 1\n",
    "    pcnt_per = 0\n",
    "    if pcnt + ncnt > 0:\n",
    "        pcnt_per = pcnt / float(pcnt + ncnt)\n",
    "    avg_per_mean = 0\n",
    "    if len(df) > 0:\n",
    "        avg_per_mean = avg_pe_sum / len(hfd)\n",
    "    \n",
    "    avg_percent = 0 if abs(avg_percent) < 0.01 else avg_percent\n",
    "    flag = ''\n",
    "    \n",
    "    \n",
    "    \n",
    "    if len(avgs) > 2:\n",
    "        \n",
    "\n",
    "        if avgs[-2] > avgs[-1] and avgs[-2] > avgs[-3] and avgs[-1] > 0:\n",
    "            flag = 'S'\n",
    "        if avgs[-2] < avgs[-1] and avgs[-2] < avgs[-3] and avgs[-1] < 0 and pcnt_per > 0:\n",
    "            flag = 'B'\n",
    "    \n",
    "            \n",
    "    return avg_percent, avg_per_mean, flag\n",
    "\n",
    "\n",
    "def kdj_flag(df):\n",
    "    matype = 0\n",
    "    # slowk      slowd\n",
    "    stoch = tfun.STOCH(df, fastk_period=21, slowk_matype=matype, slowk_period=3, slowd_period=3, slowd_matype=matype)\n",
    "    df.loc[:, 'stoch_k'] = stoch['slowk']\n",
    "    df.loc[:, 'stoch_d'] = stoch['slowd'] \n",
    "    df.loc[:, 'stoch_j'] = (stoch['slowk'] * 3 - stoch['slowd'] * 2)\n",
    "    lk = df.tail(1)\n",
    "    k = lk.stoch_k.tolist()[0]\n",
    "    d = lk.stoch_d.tolist()[0]\n",
    "    j = lk.stoch_j.tolist()[0]\n",
    "    flag = ''\n",
    "#     if j > 90:\n",
    "#         flag = 'S'\n",
    "#     if j < 10:\n",
    "#         flag = 'B'\n",
    "\n",
    "    '''\n",
    "    2021-08-11 09:30:00 (0, 0, '') {'5m': (73.36548575681029, 78.72911756526901, 62.63822213989283, False), \n",
    "    '30m': (82.77777777777777, 78.1481481481481, 92.03703703703712, True), \n",
    "    '60m': (82.02911211041298, 79.54444301577676, 86.9984502996854, True)}\n",
    "    '''\n",
    "\n",
    "\n",
    "    flag = False    \n",
    "    gold = k > d\n",
    "    #dead    \n",
    "    \n",
    "    return k, d, j, gold\n",
    "\n",
    "\n",
    "mdate = '2021-08-03'\n",
    "for t in mdt:\n",
    "    end_dt = datetime.datetime.strptime(mdate +\" \" + t + \":00\", '%Y-%m-%d %H:%M:%S')\n",
    "    sd = end_dt.strftime(\"%Y-%m-%d %H:%M:%S\")\n",
    "    snd = end_dt.strftime(\"%Y-%m-%d\")\n",
    "    \n",
    "    flags = {}\n",
    "    avg_flag = ''\n",
    "    for f in ['5m', '30m', '60m']:\n",
    "        df = dfs[f]\n",
    "        hfd1 = df[(df.date <= sd)].copy()\n",
    "        hfd = df[(df.date > snd) & (df.date <= sd)]\n",
    "        kflag = kdj_flag(hfd1)\n",
    "        flags[f] = kflag\n",
    "        \n",
    "        if f == '5m':\n",
    "            avg_lift = avg_percent(hfd, end_dt)\n",
    "            avg_flag = avg_lift[2]\n",
    "            \n",
    "    '''\n",
    "    2021-07-30 13:30:00 (-0.6537672294217645, -0.18545782219733425, 'B')\n",
    "    {'5m': (11.854792966534328, 9.802809382403064, 15.958760134796858, True), \n",
    "    '30m': (18.878205128205153, 22.5389194139194, 11.556776556776661, False), \n",
    "    '60m': (14.467923956676394, 19.17106381546261, 5.061644239103963, False)}\n",
    "    '''\n",
    "            \n",
    "    buy = flags['60m'][2] < 20 and flags['30m'][2] < 20 and flags['5m'][2] < 20\n",
    "    sell = flags['60m'][2] > 80 and flags['30m'][2] > 80 and flags['5m'][2] > 50\n",
    "    if sell:\n",
    "        print(end_dt, 'SELL', flags, 'KDJ High')\n",
    "    if buy:\n",
    "        print(end_dt,avg_lift, flags, 'KDJ LOW')       \n",
    "    if avg_flag != '':\n",
    "#         if avg_flag[3]:\n",
    "#         print(end_dt,avg_lift, flags)\n",
    "        if flags['60m'][3] == False and flags['60m'][2] > 10:\n",
    "            # sell\n",
    "            pass\n",
    "        if flags['60m'][3] == False and flags['60m'][2] > 60:\n",
    "#             print(end_dt, 'SELL')\n",
    "            pass\n",
    "        \n",
    "#         if kflag[2] < 40 and avg_flag == 'B':\n",
    "            \n",
    "#         elif avg_flag == 'S':\n",
    "#             print(t,avg_lift, kflag)\n",
    "            "
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.6.9"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 4
}
